# Maintainer: Maxime Gauduin <alucryd@archlinux.org>

pkgname=switchboard-plug-parental-controls
pkgver=6.0.1
pkgrel=1
pkgdesc='Switchboard Parental Controls Plug'
arch=(loong64 x86_64)
url=https://github.com/elementary/switchboard-plug-parental-controls
license=(GPL3)
groups=(pantheon)
depends=(
  accountsservice
  flatpak
  gdk-pixbuf2
  glib2
  gtk3
  libgee
  libgranite.so
  libmalcontent-0.so
  libswitchboard-2.0.so
  polkit
)
makedepends=(
  git
  meson
  vala
)
_tag=6e0d8595c4455c8491f273adbf694e6cc8f62a9a
source=(git+https://github.com/elementary/switchboard-plug-parental-controls.git#tag=${_tag})
sha256sums=(SKIP)

pkgver() {
  cd switchboard-plug-parental-controls

  git describe --tags
}

prepare() {
  cd switchboard-plug-parental-controls

  sed "s/dbus_dep.get_pkgconfig_variable('sysconfdir')/dbus_dep.get_pkgconfig_variable('datadir')/" -i data/meson.build
}

build() {
  arch-meson switchboard-plug-parental-controls build
  ninja -C build
}

package() {
  DESTDIR="${pkgdir}" ninja -C build install
}

# vim: ts=2 sw=2 et:
